home *** CD-ROM | disk | FTP | other *** search
/ MACD 5 / MACD 5.bin / workbench / tools / czesc_2 / justlook / examples / examplesources / mastermind.jl.h < prev    next >
C/C++ Source or Header  |  1993-12-08  |  5KB  |  114 lines

  1.  
  2.  
  3. /*  RawColumn:  1 'Del', 2 'backspaces', 1 '5'. 'return' is
  4.     the last key "pressed". */
  5. struct RawInfo RawColum[] = {   
  6.  {0x46,0}, {0x41,0}, {0x41,0}, {0x5,0}, {0x44,0}
  7. };
  8.  
  9.  
  10. struct RawInfo RawColor[] = {
  11.  {0x46,0}, {0x41,0}, {0x41,0}, {0x01,0}, {0x2,0}, {0x44,0}
  12. };
  13.  
  14.  
  15. struct RawInfo RawRow[] = {
  16.  {0x46,0}, {0x41,0}, {0x41,0}, {0x4,0}, {0x44,0}
  17. };
  18.  
  19.  
  20. char Blank[] = "                                                ";
  21. struct TextAttr ROMFont = {"topaz.font",TOPAZ_EIGHTY,FS_NORMAL,FPF_ROMFONT};
  22.  
  23. struct IntuiText TextToShow[6] = {
  24.   {1,0,JAM2,10,15,&ROMFont,Blank,NULL},
  25.   {1,0,JAM2,10,25,&ROMFont,Blank,&TextToShow[0]},
  26.   {1,0,JAM2,10,35,&ROMFont,Blank,&TextToShow[1]},
  27.   {1,0,JAM2,10,45,&ROMFont,Blank,&TextToShow[2]},
  28.   {1,0,JAM2,10,55,&ROMFont,Blank,&TextToShow[3]},
  29.   {1,0,JAM2,10,65,&ROMFont,Blank,&TextToShow[4]} };
  30.  
  31. struct IntuiText BlankLine =  {1,0,JAM2,10,65,&ROMFont,Blank,NULL}; 
  32.  
  33. struct NewWindow JLNewWindow = { 20,15,552,120,0,1,NULL,WFLG_SIZEGADGET,NULL,
  34.   NULL,"JustLook's Window!",NULL,NULL,80,40,1280,512,CUSTOMSCREEN };
  35.  
  36. char *Mess[] = {
  37. "             Welcome To MasterMind!             ", /* 1 */
  38. "                                                ",
  39. "         MasterMind is © Kamran Karimi          ",
  40. "This demo was prepared using JustLook routines. ",
  41. "                                                ",
  42. "LEFT Button to Continue    RIGHT Button to Quit ",
  43.  
  44. "MasterMind is a simple but interesting game: The", /* 2 */
  45. "Amiga will choose some colors randomly and you  ",
  46. "have to guess not only the colors, but also the ",
  47. "columns on which they are put by the Amiga!     ",
  48. "                                                ",
  49. "LEFT Button to Continue    RIGHT Button to Quit ",
  50.  
  51. "This implementation of the game is quite        ", /* 3 */
  52. "configurable. You can change important prameters",
  53. "of it easily. The game adapts itself to both PAL",
  54. "and NTSC screen characteristics                 ",
  55. "                                                ",
  56. "LEFT Button to Continue    RIGHT Button to Quit ", 
  57.    
  58. "The board has been configured to our likings.   ", /* 4 */
  59. "We can now start playing. To select a color,    ",
  60. "simply click the mouse on it. Then bring the    ",
  61. "pointer over the square you like and click again",
  62. "                                                ",
  63. "LEFT Button to Continue    RIGHT Button to Quit ",
  64.  
  65. "after you are done with a row, click on the     ", /* 5 */
  66. " '<- Done'  gadget to see the results. all the  ",
  67. "squares in a row should be filled before this,  ",
  68. "otherwise you'll get an error  message          ",
  69. "                                                ",
  70. "LEFT Button to Continue    RIGHT Button to Quit ", 
  71.  
  72. "So we should fill the remaining square with a   ", /* 6 */
  73. "color...                                        ",
  74. "                                                ",
  75. "                                                ",
  76. "                                                ",
  77. "LEFT Button to Continue    RIGHT Button to Quit ",
  78.  
  79. "Now all the squares are filled, but wrongly!.   ", /* 7 */
  80. "You should not use a color more than one time in",
  81. "the same row!                                   ",
  82. "                                                ",
  83. "                                                ",
  84. "LEFT Button to Continue    RIGHT Button to Quit ",
  85.  
  86. "Now it is better!.                              ", /* 8 */
  87. "Lets see what we have done...                   ",
  88. "                                                ",
  89. "                                                ",
  90. "                                                ",
  91. "LEFT Button to Continue    RIGHT Button to Quit ",
  92.  
  93. "you can also cheat if you want! click on the    ", /* 9 */
  94. "Cheat gadget and it will show  you a color which",
  95. "is among the ones the Amiga has chosen, but it  ",
  96. "won't tell to which column it belongs.          ",
  97. "                                                ",
  98. "LEFT Button to Continue    RIGHT Button to Quit ", 
  99.  
  100. "This should be enought to show you how to use   ", /* 10 */
  101. "MasterMind. You can stop the game any time by   ",
  102. "clicking on the Abort gadget and that is exaclty",
  103. "what we are going to do now!. Good-Bye          ",
  104. "                                                ",
  105. "                Press Any Button                ",
  106.  
  107. "Winning in the FIRST try!!!                     ", /* 11 */
  108. "                                                ",
  109. "                                                ",
  110. "                                                ",
  111. "                                                ",
  112. "LEFT Button to Continue    RIGHT Button to Quit "  
  113. };
  114.